﻿using System.Collections.Generic;

namespace DuplicateFileFinder.Model
{
    public class HasherOutputQueue<T>
    {
        public static HasherOutputQueue<T> Instance = new HasherOutputQueue<T>();

        private volatile Queue<T> _queue;

        private HasherOutputQueue()
        {
            _queue = new Queue<T>();
        }

        public void EnQueue(T obj)
        {
            _queue.Enqueue(obj);
        }

        public T DeQueue()
        {
            return _queue.Dequeue();
        }
    }
}
